<?php if (!defined('BASEPATH')) exit('No direct script access allowed');

class mdl_setting_nis extends CI_Model {
    
	function __construct(){
		parent::__construct();
	}
	
	function get_data_edit(){
		$this->db->flush_cache();
		$this->db->select('*');
		$this->db->from('tbl_ref_sd_setting_nis');
		
		return $this->db->get();
	}
	
	function update($data){
		//query insert data		
		$this->db->flush_cache();
		$this->db->set('awalan', $data['awalan']);
		$this->db->set('digit', $data['digit']);
		
		$this->db->where('id', $data['id']);
		
		$result = $this->db->update('tbl_ref_sd_setting_nis');
		
		//return
		if($result) {
			return TRUE;
		}else {
			return FALSE;
		}
	}
	
}

?>